package com.wql.rabbitmq.study;

import com.rabbitmq.client.Channel;
import com.wql.rabbitmq.ChannelFactory;
import com.wql.rabbitmq.Constant;

public class PubSubTestForProducter {

	public static void main(String[] args) throws Exception {
		Channel channel = ChannelFactory.getChannel();
		channel.exchangeDeclare(Constant.PUBSUB_NAME, "fanout");
		String msg = "hello world";
		channel.basicPublish(Constant.PUBSUB_NAME, "", null, msg.getBytes());
		System.out.println("producter start");
	}
}
